﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.ComponentModel.DataAnnotations;

namespace MyVoteMVC.Domain
{
    public class VT_Projects
    {
        public VT_Projects()
        {
            Items = new List<VT_Items>();
        }

        /// <summary>
        /// PK Guid
        /// </summary>
        public string Project_ID { get; set; }

        /// <summary>
        /// 年份
        /// </summary>
        public string Project_Year { get; set; }

        /// <summary>
        /// 地址
        /// </summary>
        public string Project_Address { get; set; }

        /// <summary>
        /// 名称
        /// </summary>
        public string Project_Name { get; set; }

        /// <summary>
        /// 类型
        /// </summary>
        public string Project_Type { get; set; }

        /// <summary>
        /// 获奖情况
        /// </summary>
        public string Project_Awards { get; set; }

        public string Project_Description { get; set; }

        /// <summary>
        /// 相关图片
        /// </summary>
        public virtual VT_ProjectImage ProjectImage { get; set; }

        /// <summary>
        /// 关联了该项目的相关的选项
        /// </summary>
        public virtual ICollection<VT_Items> Items { get; set; }
    }

    public class VT_ProjectImage
    {
        public VT_ProjectImage()
        {

        }

        [Key]
        /// <summary>
        /// PK Guid
        /// </summary>
        public string Project_ID { get; set; }

        /// <summary>
        /// 选项图片
        /// </summary>
        public byte[] Project_Image { get; set; }

        public byte[] Project_Thumbnail { get; set; }
    }
}
